﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Web.master" AutoEventWireup="true" CodeBehind="HallSearchResult.aspx.cs" Inherits="badminton.Pages.HallSearchResult" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit"  TagPrefix="ajaxToolkit" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
<table border="0" cellspacing="0" cellpadding="0" width="100%">
    <tr>
        <td>
        <table border="0" cellspacing="0" cellpadding="2" width="100%">
        	<tr>
        		<td width="250" valign="top" >
                        <table border="0" cellspacing="0" cellpadding="2" width="100%" 
                            bgcolor="#006699" style="color: #FFFFFF">
                            <tr>
                                <td>
                                所在城区
                                </td>
                                <td>
                                    <asp:DropDownList ID="DropDownListCityArea" runat="server" OnSelectedIndexChanged="OnCityAreaSelectedIndexChanged" Width="120" AutoPostBack="True">
                                    </asp:DropDownList>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                所在球馆
                                </td>
                                <td>
                                    <asp:DropDownList ID="DropDownListHall" runat="server" Width="120">
                                    </asp:DropDownList>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                开始时间
                                </td>
                                <td>
                                    <asp:TextBox ID="TextBoxStartTime" runat="server" Width="120"></asp:TextBox>
                                    <ajaxToolkit:CalendarExtender
                                        ID="CalendarExtender1" runat="server" TargetControlID="TextBoxStartTime" Format="yyyy.MM.dd hh:mm">
                                    </ajaxToolkit:CalendarExtender>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                预约时长
                                </td>
                                <td>
                                    <asp:TextBox ID="TextBoxTimeSpan" Text='0' runat="server"></asp:TextBox>
                                    <ajaxToolkit:NumericUpDownExtender ID="NumericUpDownExtender1" runat="server" Step="0.5" Minimum="0" Maximum="12" TargetControlID="TextBoxTimeSpan" Width="90">
                                    </ajaxToolkit:NumericUpDownExtender>小时
                                </td>
                            </tr>
                            <tr>
                                <td colspan=2 align="right">
                                    <asp:Button ID="ButtonSearchHall" runat="server" Text="搜索场地"               
                                        oncommand="OnSearchCourt" />
                                </td>
                            </tr>
                        </table>
                </td>
                <td>
                    <asp:Repeater ID="Repeater1" runat="server">
                        <HeaderTemplate>
                            <table class="thinframetable" border="0" cellspacing="1" cellpadding="0" width="100%">
                            <tr class="thinframetable"><td class="title" colspan=3>场馆预约查询结果</td></tr>
                            <tr class="thinframetable">
                            <th>球馆名称</th> <th>所在城区</th> <th align="center">球馆安排<br><img alt="" src="../images/courtschedule/24hour.PNG" /></th> 
                            </tr>
                        </HeaderTemplate>
                        <ItemTemplate>
                            <tr class="thinframetable">
                            <td>
                                <a href='./HallDetail.aspx?hallid=<%# Eval("id") %>'><%# Eval("name") %></a>
                            </td>
                            <td>
                                <%# GetCityAreaName(Eval("id")) %>
                            </td>
                            <td>
                                <%# GetCourtSchedule(Eval("id")) %>
                            </td>
                            </tr>
                        </ItemTemplate>
                        <AlternatingItemTemplate>
                            <tr class="thinframetable_altern">
                            <td>
                                <a href='./HallDetail.aspx?hallid=<%# Eval("id") %>'><%# Eval("name") %></a>
                            </td>
                            <td>
                                <%# GetCityAreaName(Eval("id")) %>
                            </td>
                            <td>
                                <%# GetCourtSchedule(Eval("id")) %>
                            </td>
                            </tr>
                        </AlternatingItemTemplate>
                        <FooterTemplate>
                            </table>
                        </FooterTemplate>
                    </asp:Repeater>
                </td>
        	</tr>
        </table>
        </td>
    </tr>
</table>

</asp:Content>
